#ifndef __OD_H265_SDP_MATCH_H__
#define __OD_H265_SDP_MATCH_H__


/**
 * @file od_h265_sdp_match.h
 * @brief Special SDP format match for h265.
 */

#include <pjmedia/sdp_neg.h>

#ifdef __cplusplus
    extern "C" {
#endif


/**
 * Definition of H.264 parameters.
 */
typedef struct pjmedia_vid_codec_h265_fmtp
{
    /* profile-level-id */
    pj_uint8_t    profile_idc;      /**< Profile ID    */
    pj_uint8_t    profile_iop;      /**< Profile constraints bits    */
    pj_uint8_t    level;	        /**< Level    */

    /* packetization-mode */
    pj_uint8_t    packetization_mode;/**< Packetization mode    */

    /* max-ls, max-lps, max-cpb, max-dpb, and max-br */
    unsigned    max_lsr;      /**< Max luma sample rate()    */
    unsigned    max_lps;     /**< Max frame size (in macroblocks)    */
    //unsigned    max_cpb;   /**< Max coded picture buffer size    */
    //unsigned    max_dpb;   /**< Max decoded picture buffer size    */
    //unsigned    max_br;    /**< Max video bit rate    */

    /* sprop-parameter-sets, in NAL units */
    pj_size_t     sprop_param_sets_len;   /**< Parameter set length    */
    pj_uint8_t    sprop_param_sets[256];  /**< Parameter set (SPS & PPS),
 in NAL unit bitstream    */

} pjmedia_vid_codec_h265_fmtp;


/**
 * Match h265 format in the SDP media offer and answer. This function
 * will match h265 bitrate setting in the SDP format parameter of
 * offer and answer.
 *
 * @param pool          The memory pool.
 * @param offer         The SDP media offer.
 * @param o_fmt_idx     Index of the H.264 format in the SDP media offer.
 * @param answer        The SDP media answer.
 * @param a_fmt_idx     Index of the H.264 format in the SDP media answer.
 * @param option        The format matching option, see
 *                      #pjmedia_sdp_neg_fmt_match_flag.
 *
 * @return              PJ_SUCCESS when the formats in offer and answer match.
 */
PJ_DECL(pj_status_t) od_codec_h265_match_sdp( pj_pool_t *pool,
                                              pjmedia_sdp_media *offer,
                                              unsigned o_fmt_idx,
                                              pjmedia_sdp_media *answer,
                                              unsigned a_fmt_idx,
                                              unsigned option);



#ifdef __cplusplus
    }
#endif

#endif	/* __OD_H265_SDP_MATCH_H__ */

